Get Campaigns API
This endpoint allows you to retrieve a list of all campaigns.
Endpoint
GET https://www.toingg.com/api/v3/get_campaigns
Headers
accept: application/json
Authorization: Bearer YOUR_ACCESS_TOKEN
Example Code
Python
import requests
url = "https://www.toingg.com/api/v3/get_campaigns"
headers = {
"accept": "application/json",
"Authorization": "Bearer YOUR_ACCESS_TOKEN"
}
response = requests.get(url, headers=headers)
print(response.text)
JavaScript
const fetch = require('node-fetch');
const url = 'https://www.toingg.com/api/v3/get_campaigns';
const headers = {
'accept': 'application/json',
'Authorization': 'Bearer YOUR_ACCESS_TOKEN'
};
fetch(url, {
method: 'GET',
headers: headers
})
.then(response => response.json())
.then(data => console.log(data))
.catch(error => console.error('Error:', error));
Responses
Code | Description | Links |
---|---|---|
200 | Successful Response | No links |
400 | Bad Request | No links |
Response Details
200 - Successful Response
- Media type: application/json
- Example Value:
"string"
400 - Bad Request
- Response body:
{
"detail": "Campaigns not found"
}